package com.mce.nebula.dto;

import com.mce.nebula.entity.TenantService;
import lombok.Data;
import java.time.LocalDateTime;
import java.util.Map;

/**
 * 应用响应DTO
 */
@Data
public class AppResponse {

    public AppResponse(TenantService tenantService){
        this.appAlias=tenantService.getServiceAlias();
//        this.appId=tenantService.getId();
    }

    private Integer appId;
    private String appName;
    private String appAlias;
    private String appDescription;
    private Integer teamId;
    private String teamName;
    private String appType;
    private String sourceType;
    private String sourceUrl;
    private String dockerImage;
    private String buildPack;
    private String language;
    private String version;
    private String namespace;
    private String status; // 应用状态：running, stopped, building等
    private String deployType; // 部署类型：source, image, docker-compose等
    private Integer replicas; // 副本数量
    private Integer cpu; // CPU限制
    private Integer memory; // 内存限制
    private Integer storage; // 存储限制
    private LocalDateTime createTime;
    private LocalDateTime updateTime;
    private String creator;
    private Map<String, Object> config; // 应用配置
    private Map<String, Object> envVars; // 环境变量
    private Map<String, Object> ports; // 端口配置
    private Map<String, Object> volumes; // 存储卷配置
}